package lk.icta.common.entity;

import javax.persistence.*;
import java.util.Date;

/**
 * Created with IntelliJ IDEA.
 * User: root
 * Date: 10/17/12
 * Time: 10:07 AM
 * To change this template use File | Settings | File Templates.
 */
@Entity
@Table(schema = "COMMON_RAIL")
@NamedQueries({
        @NamedQuery(name = "findCurrentPresident", query = "SELECT p FROM President p WHERE NOW() BETWEEN p.startDate AND p.endDate")
})
public class President extends BaseEntity {
    /**
     * Name of President
     */
    @Column(nullable = false)
    private String fullEnName;

    @Column(nullable = false)
    private String fullSiName;

    @Column(nullable = false)
    private String fullTaName;

    /**
     * startDate
     */
    @Column(nullable = true)
    @Temporal(value = TemporalType.DATE)
    private Date startDate;

    /**
     * endtDate
     */
    @Column(nullable = true)
    @Temporal(value = TemporalType.DATE)
    private Date endDate;

    public String getFullEnName() {
        return fullEnName;
    }

    public void setFullEnName(String fullName) {
        this.fullEnName = fullName;
    }

    public String getFullSiName() {
        return fullSiName;
    }

    public void setFullSiName(String fullSiName) {
        this.fullSiName = fullSiName;
    }

    public String getFullTaName() {
        return fullTaName;
    }

    public void setFullTaName(String fullTaName) {
        this.fullTaName = fullTaName;
    }

    public Date getStartDate() {
        return startDate;
    }

    public void setStartDate(Date startDate) {
        this.startDate = startDate;
    }

    public Date getEndDate() {
        return endDate;
    }

    public void setEndDate(Date endDate) {
        this.endDate = endDate;
    }
}
